package com.kaisheng.service;

import java.util.List;

import com.kaisheng.dao.TaskDao;
import com.kaisheng.entity.Task;

public class TaskService {

	TaskDao td = new TaskDao();
	
	public List<Task> findById(String project_id,String user_id) {
		return td.findById(project_id,user_id);
	
	}

	public List<Task> findByProjectId(String project_Id) {
		return td.findById(project_Id);
	}

	public Task findByTaskId(String task_id) {
		return td.findByTaskId(task_id);
	}

	public List<Task> findByGoalId(String goal_id) {
		return td.findByGoalId(goal_id);
	}

	public boolean save(String name, String begintime, String endtime,
			String describe, String status, String rank, String manager,String goal_id) {
		return td.save(name,begintime,endtime,describe,status,rank,manager,goal_id);		
	}

	public boolean update(String name, String begintime, String endtime,
			String describe, String status, String rank, String manager,
			float rate,String task_id) {
		return td.update(name,begintime,endtime,describe,status,rank,manager,rate,task_id);
	}
}
